package com.huilian.iotbox.mqtt.server.base.service.impl;

import com.huilian.iotbox.mqtt.server.base.dao.MessageLogDao;
import com.huilian.iotbox.mqtt.server.base.service.MessageLogService;
import com.huilian.iotbox.data.po.MessageLog;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * MessageLogServiceImpl
 *
 * @Author mineChen
 * @Date 2021/10/29 下午 02:50
 */
@Service
public class MessageLogServiceImpl implements MessageLogService {

    @Autowired
    private MessageLogDao messageLogDao;

    @Override
    public int insert(MessageLog messageLog) {
        return messageLogDao.insert(messageLog);
    }

    @Override
    public List<MessageLog> findAllByCondition(String deviceNo, String startTime, String endTime, Integer type) {
        return messageLogDao.findAllByCondition(deviceNo, startTime, endTime, type);
    }
}
